<!doctype html>
<html lang="ch" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8">
    <title>订单详情</title>
    <link rel="stylesheet" type="text/css" th:href="@{user_center/css/identify.css}" />
    <link rel="stylesheet" type="text/css" th:href="@{user_center/css/layout.css}" />
    <link rel="stylesheet" type="text/css" th:href="@{user_center/css/account.css}" />
    <link rel="stylesheet" type="text/css" th:href="@{user_center/css/style.css}" />
    <link rel="stylesheet" type="text/css" th:href="@{user_center/css/control_index.css}" />
    <link rel="stylesheet" type="text/css" th:href="@{css/timeTo.css}" />
    <script type="text/javascript" th:src="@{user_center/js/jquery-1.7.2.min.js}"></script>
    <script type="text/javascript" th:src="@{user_center/js/layer/layer.js}"></script>
    <script type="text/javascript" th:src="@{user_center/js/haidao.offcial.general.js}"></script>
    <script type="text/javascript" th:src="@{user_center/js/select.js}"></script>
    <script type="text/javascript" th:src="@{user_center/js/haidao.validate.js}"></script>
    <script type="text/javascript" th:src="@{js/jquery.time-to.min.js}"></script>
    <style>
        .table tr th {
            text-align: center !important;
        }
        .table tr td {
            text-align: center !important;
        }
    </style>
</head>

<body>
<div th:replace="common/common::#lefttop"></div>

<div class="view-body">

    <div th:replace="common/common::#left"></div>

    <div class="view-product">
        <div class="info-center">
            <div class="manage-head">
                <h6 class="padding-left manage-head-con">订单详情</h6>
            </div>
            <div class="offcial-table input-table table-margin clearfix">
                <div class="tr-th clearfix">
                    <div class="th w5 text-center"><!--<input class="margin-top-15" type="checkbox" />--></div>
                    <div class="th w15">订单号</div>
                    <div class="th w10">创建时间</div>
                    <div class="th w20">订单有效期</div>
                    <div class="th w10">手机号码</div>
                    <div class="th w25">收货地址</div>
                    <div class="th w15 text-center">操作</div>
                </div>

                <div class="tr-th clearfix">
                    <div class="th w5 text-center"><!--<input class="margin-top-15" type="checkbox" />--></div>
                    <div class="th w15">[[${order.orderid}]]</div>
                    <div class="th w10">[[${order.creationtime}]]</div>

                    <div class="th w20" id="timeCount" th:if="${redistime>0} and ${order.paymentstatus==0}"></div>
                    <div class="th w20" th:if="${redistime}<=0 and ${order.paymentstatus==0}">已失效</div>
                    <div class="th w20" th:if="${redistime}>=0 and ${order.paymentstatus==1}">已下单</div>
                    <div class="th w10">[[${user.phone}]]</div>
                    <div class="th w25">[[${order.address}]]</div>
                    <div class="th w15 text-center" th:if="${redistime>0} and ${order.paymentstatus==0}"><a th:href="@{'/redisoverdue?orderid='+${order.orderid}}">取消订单</a></div>
                    <div class="th w15 text-center" th:if="${redistime}>=0 and ${order.paymentstatus==1}"><span>已下单</span></div>
                </div>


            </div>


            <!--            <div class="tr non-info show border-bottom-none">-->
            <!--                <span>没查询到符合条件的记录</span>-->
            <!--            </div>-->
<!--            商品详情-->
            <div class="table-margin" style="margin-top: 3%">
                <table class="table">
<!--                    <caption>商品详情</caption>-->

                    <thead>
                    <tr class="text-center">
                        <th>商品名称</th>
                        <th>商品数量</th>
                        <th>商品单价</th>

                    </tr>
                    </thead>

                    <tbody th:each="details:${detail_orders}">
                    <tr>
                        <td>[[${details.name}]]</td>
                        <td>[[${details.count}]]</td>
                        <td>[[${details.price}]]</td>
                    </tr>

                    </tbody>
                </table>
            </div>

        </div>
    </div>
    <div class="show-page padding-big-right hidden">
        <div class="page">
        </div>
    </div>
</div>


<script>
    $(".sidebar-title").live('click', function () {
        if ($(this).parent(".sidebar-nav").hasClass("sidebar-nav-fold")) {
            $(this).next().slideDown(200);
            $(this).parent(".sidebar-nav").removeClass("sidebar-nav-fold");
        } else {
            $(this).next().slideUp(200);
            $(this).parent(".sidebar-nav").addClass("sidebar-nav-fold");
        }
    });
    $('#timeCount').timeTo({
        seconds: [[${redistime}]],
        displayHours: false
    });
</script>
</body>

</html>
